package com.util;

import java.util.Arrays;
import java.util.List;

public class CheckFile {
	public static boolean checkImage(String imageName){
		List<String> list=Arrays.asList(new String[]{"JPG","WEBP","BMP","GIF","PCX","TIF","GIF","JPEG","TGA","EXIF","FPX",
				"SVG","PSD","CDR","PCD","DXF","UFO","EPS","AI","PNG","HDRI","RAW","WMF","FLIC","EMF","ICO"});
		if(list.contains(imageName.substring(imageName.lastIndexOf(".")+1).toUpperCase())){
			return true;
		}
		return false; 
	}
}
